﻿using CrawlerFramework.Translator;
using System;
using System.Collections.Generic;
using System.Data.Entity;

namespace CrawlerFramework.DataConverter
{
    public interface IDataConverter:IDisposable
    {
        DbContext SourceContext { get; }

        DbContext TargetContext { get; }

        ITranslateService TranslateService { get; set; }

        /// <summary>
        /// Migrate all data from source context to target context
        /// </summary>
        void Migrate();

        /// <summary>
        /// Migrate just only one record from source context to target context
        /// </summary>
        /// <param name="id"></param>
        void MigrateOneRecord(int id);

        /// <summary>
        /// Migrate more than one records for source context to target context
        /// </summary>
        /// <param name="ids"></param>
        void MigrateManyRecords(IEnumerable<int> ids);

        void RemoveOneRecord(int id);

        void RemoveManyRecords(IEnumerable<int> ids);
    }
}